Skip to content

Conversation

@AdnaneKhan
Copy link

Scope Down GitHub Token Permissions

This PR updates GitHub Actions workflows to use minimal required permissions instead of the default elevated permissions.

Why This Matters

Following the principle of least privilege, workflows should only have the specific permissions they need to function.

Changes

This PR adds explicit permissions: blocks to workflows that currently rely on default permissions, scoping them down to only what's required for their operations.

Please review the changes to ensure the specified permissions match your workflow requirements.

@AdnaneKhan AdnaneKhan marked this pull request as ready for review October 21, 2025 21:23
Copy link
Contributor

@marofke marofke left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for your submission! I just have one change I think we'll need to make to ensure we preserve our existing behaviour.

paths:
- .github/config/labels.yml

permissions:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we'll also need pull-request:write since our labels also need to be applied to PRs https://github.com/aws/aws-rfdk/blob/mainline/.github/config/labels.yml

@marofke marofke added the response-requested Waiting on additional info and feedback. Will move to 'closing-soon' in 7 days. label Nov 7, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

response-requested Waiting on additional info and feedback. Will move to 'closing-soon' in 7 days.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants